<html>
<head><meta charset="utf-8"><title>stderr files in ui tests · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/stderr.20files.20in.20ui.20tests.html">stderr files in ui tests</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="216360932"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/stderr%20files%20in%20ui%20tests/near/216360932" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> BN <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/stderr.20files.20in.20ui.20tests.html#216360932">(Nov 11 2020 at 15:36)</a>:</h4>
<p>Are the normalizations produced by the compiler itself or do I have to manually replace the line numbers in the error messages with <code>LL</code> and the path with <code>$DIR</code>?</p>



<a name="216361721"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/stderr%20files%20in%20ui%20tests/near/216361721" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> BN <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/stderr.20files.20in.20ui.20tests.html#216361721">(Nov 11 2020 at 15:42)</a>:</h4>
<p>Basically my question is whether I can just copy the error message I get from running a test case into the .stderr file or whether I have to replace the directory names and the line numbers?</p>



<a name="216363936"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/stderr%20files%20in%20ui%20tests/near/216363936" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Eric Huss <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/stderr.20files.20in.20ui.20tests.html#216363936">(Nov 11 2020 at 15:58)</a>:</h4>
<p><span class="user-mention" data-user-id="328097">@BN</span> Usually the <code>--bless</code> flag is used to generate the <code>.stderr</code> files. That handles all the normalization that compiletest performs.  There's also some interaction with rustc which normalizes some output via the <code>-Zui-testing</code> flag, but compiletest adds some additional translations.  You could, in theory, write it manually, but is there some reason you can't use <code>--bless</code>?</p>



<a name="216364613"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/stderr%20files%20in%20ui%20tests/near/216364613" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> BN <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/stderr.20files.20in.20ui.20tests.html#216364613">(Nov 11 2020 at 16:03)</a>:</h4>
<p>Thanks a lot, I didn't know about the <code>--bless</code> option.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>